home *** CD-ROM | disk | FTP | other *** search
/ Chip 2007 January, February, March & April / Chip-Cover-CD-2007-02.iso / Pakiet bezpieczenstwa / mini Pentoo LiveCD 2006.1 / mpentoo-2006.1.iso / livecd.squashfs / usr / lib / mozilla-firefox / include / necko / nsISocketTransportService.h < prev    next >
C/C++ Source or Header  |  2006-05-08  |  4KB  |  114 lines

  1. /*
  2.  * DO NOT EDIT.  THIS FILE IS GENERATED FROM nsISocketTransportService.idl
  3.  */
  4.  
  5. #ifndef __gen_nsISocketTransportService_h__
  6. #define __gen_nsISocketTransportService_h__
  7.  
  8.  
  9. #ifndef __gen_nsISupports_h__
  10. #include "nsISupports.h"
  11. #endif
  12.  
  13. /* For IDL files that don't want to include root IDL files. */
  14. #ifndef NS_NO_VTABLE
  15. #define NS_NO_VTABLE
  16. #endif
  17. class nsISocketTransport; /* forward declaration */
  18.  
  19. class nsIProxyInfo; /* forward declaration */
  20.  
  21.  
  22. /* starting interface:    nsISocketTransportService */
  23. #define NS_ISOCKETTRANSPORTSERVICE_IID_STR "7b19ac06-a5fb-11d9-9f82-0011246ecd24"
  24.  
  25. #define NS_ISOCKETTRANSPORTSERVICE_IID \
  26.   {0x7b19ac06, 0xa5fb, 0x11d9, \
  27.     { 0x9f, 0x82, 0x00, 0x11, 0x24, 0x6e, 0xcd, 0x24 }}
  28.  
  29. class NS_NO_VTABLE nsISocketTransportService : public nsISupports {
  30.  public: 
  31.  
  32.   NS_DEFINE_STATIC_IID_ACCESSOR(NS_ISOCKETTRANSPORTSERVICE_IID)
  33.  
  34.   /**
  35.      * Creates a transport for a specified host and port.
  36.      *
  37.      * @param aSocketTypes
  38.      *        array of socket type strings.  null if using default socket type.
  39.      * @param aTypeCount
  40.      *        specifies length of aSocketTypes.
  41.      * @param aHost
  42.      *        specifies the target hostname or IP address literal of the peer
  43.      *        for this socket.
  44.      * @param aPort
  45.      *        specifies the target port of the peer for this socket.
  46.      * @param aProxyInfo
  47.      *        specifies the transport-layer proxy type to use.  null if no
  48.      *        proxy.  used for communicating information about proxies like
  49.      *        SOCKS (which are transparent to upper protocols).
  50.      * 
  51.      * @see nsIProxiedProtocolHandler
  52.      * @see nsIProtocolProxyService::GetProxyInfo
  53.      */
  54.   /* nsISocketTransport createTransport ([array, size_is (aTypeCount)] in string aSocketTypes, in unsigned long aTypeCount, in AUTF8String aHost, in long aPort, in nsIProxyInfo aProxyInfo); */
  55.   NS_IMETHOD CreateTransport(const char **aSocketTypes, PRUint32 aTypeCount, const nsACString & aHost, PRInt32 aPort, nsIProxyInfo *aProxyInfo, nsISocketTransport **_retval) = 0;
  56.  
  57. };
  58.  
  59. /* Use this macro when declaring classes that implement this interface. */
  60. #define NS_DECL_NSISOCKETTRANSPORTSERVICE \
  61.   NS_IMETHOD CreateTransport(const char **aSocketTypes, PRUint32 aTypeCount, const nsACString & aHost, PRInt32 aPort, nsIProxyInfo *aProxyInfo, nsISocketTransport **_retval); 
  62.  
  63. /* Use this macro to declare functions that forward the behavior of this interface to another object. */
  64. #define NS_FORWARD_NSISOCKETTRANSPORTSERVICE(_to) \
  65.   NS_IMETHOD CreateTransport(const char **aSocketTypes, PRUint32 aTypeCount, const nsACString & aHost, PRInt32 aPort, nsIProxyInfo *aProxyInfo, nsISocketTransport **_retval) { return _to CreateTransport(aSocketTypes, aTypeCount, aHost, aPort, aProxyInfo, _retval); } 
  66.  
  67. /* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
  68. #define NS_FORWARD_SAFE_NSISOCKETTRANSPORTSERVICE(_to) \
  69.   NS_IMETHOD CreateTransport(const char **aSocketTypes, PRUint32 aTypeCount, const nsACString & aHost, PRInt32 aPort, nsIProxyInfo *aProxyInfo, nsISocketTransport **_retval) { return !_to ? NS_ERROR_NULL_POINTER : _to->CreateTransport(aSocketTypes, aTypeCount, aHost, aPort, aProxyInfo, _retval); } 
  70.  
  71. #if 0
  72. /* Use the code below as a template for the implementation class for this interface. */
  73.  
  74. /* Header file */
  75. class nsSocketTransportService : public nsISocketTransportService
  76. {
  77. public:
  78.   NS_DECL_ISUPPORTS
  79.   NS_DECL_NSISOCKETTRANSPORTSERVICE
  80.  
  81.   nsSocketTransportService();
  82.  
  83. private:
  84.   ~nsSocketTransportService();
  85.  
  86. protected:
  87.   /* additional members */
  88. };
  89.  
  90. /* Implementation file */
  91. NS_IMPL_ISUPPORTS1(nsSocketTransportService, nsISocketTransportService)
  92.  
  93. nsSocketTransportService::nsSocketTransportService()
  94. {
  95.   /* member initializers and constructor code */
  96. }
  97.  
  98. nsSocketTransportService::~nsSocketTransportService()
  99. {
  100.   /* destructor code */
  101. }
  102.  
  103. /* nsISocketTransport createTransport ([array, size_is (aTypeCount)] in string aSocketTypes, in unsigned long aTypeCount, in AUTF8String aHost, in long aPort, in nsIProxyInfo aProxyInfo); */
  104. NS_IMETHODIMP nsSocketTransportService::CreateTransport(const char **aSocketTypes, PRUint32 aTypeCount, const nsACString & aHost, PRInt32 aPort, nsIProxyInfo *aProxyInfo, nsISocketTransport **_retval)
  105. {
  106.     return NS_ERROR_NOT_IMPLEMENTED;
  107. }
  108.  
  109. /* End of implementation class template. */
  110. #endif
  111.  
  112.  
  113. #endif /* __gen_nsISocketTransportService_h__ */
  114.